D:\www_msal\kyzs2016\protected\controllers\ServiceController.php(150)
138 $consql="select s.serviceid,s.name,l.labname, s.labid from ta_service s left join ta_lab l on s.labid=l.labid where s.isdelete = 0 and s.typeid=".$detail['tid']." limit 0, 10";
139 $coninfo = Yii::app()->db->createCommand($consql)->queryAll();
140
141 //成交记录
142 $contractsql = "select c.*,u.username, u.truename, sc.score, sc.memo, sc.dt, fc.sendsampleno from ta_contract c "
143 . "left join ta_user u on c.first=u.uid "
144 . "left join ta_fastcontract fc on fc.contractno = c.contractno "
145 . "left join ta_contractscore sc on sc.contractno = c.contractno "
146 . "where c.state in(50) and c.isdelete = 0 and exists(select * from {{sampleschecklist}} where contractno = c.contractno and checkno = $detail[serviceid]) order by contractno asc limit 0, 15";
147 $contract = Yii::app()->db->createCommand($contractsql)->queryAll();
148 }
149
150 $this->pageTitle = $detail['name'].' - '.Yii::app()->name;
151 Yii::app()->clientScript->registerMetaTag($detail['name'].', '.$detail['typename'].', '.$detail['devname'].', '.'科研助手, LIMS, 仪器预约, 科研管理, 实验室, 科研合作, 科研需求','keywords');
152 Yii::app()->clientScript->registerMetaTag(preg_replace('/(;)/i','',strip_tags($detail['intro'])), 'description');
153
154 //2017-03-29
155 //相关服务
156 $typeid = intval($detail['typeid']);
157 $sql = "select * from {{service}} where isdelete = 0 and isshow = 1 and typeid = $typeid and serviceid $detail[serviceid] order by clickcount desc limit 0, 15";
158 $hotlist = Yii::app()->db->createCommand($sql)->queryAll();
159
160 //咨询
161 $model = new Ask;
162
|